package com.ztgf.order.models.vo;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.ztgf.common.annotations.CustomerBigDecimalSerialize;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 订单发票管理VO
 *
 * @author chenyu.wang
 * @Date 2020-06-03 15:58:16
 */
@Data
public class OrderInvoiceVO implements Serializable {
    @ApiModelProperty(value = "订单发票表id")
    private Long id;

    @ApiModelProperty(value = "卖家店铺id")
    private Long sellerShopId;

    @ApiModelProperty(value = "买家店铺id")
    private Long buyerShopId;

    @ApiModelProperty(value = "订单id")
    private Long orderId;

    @ApiModelProperty(value = "公司名称")
    private String companyName;

    @ApiModelProperty(value = "纳税人识别号")
    private String taxpayerId;

    @ApiModelProperty(value = "收票人手机")
    private String buyerPhone;

    @ApiModelProperty(value = "收票人邮箱")
    private String buyerEmail;

    @ApiModelProperty(value = "发票图片")
    private String invoiceUrl;

    @ApiModelProperty(value = "类型 0纸质发票，1电子发票")
    private Integer type;

    @ApiModelProperty(value = "发票类型 1普票，0专票")
    private Integer invoiceType;

    @ApiModelProperty(value = "发票内容")
    private String invoiceContent;

    @ApiModelProperty(value = "发票金额")
    @JsonSerialize(using = CustomerBigDecimalSerialize.class)
    private BigDecimal invoicePrice;

    @ApiModelProperty(value = "邮政编码")
    private String postalCode;

    @ApiModelProperty(value = "收票人姓名")
    private String receivingName;

    @ApiModelProperty(value = "区域id")
    private Long areaId;

    @ApiModelProperty(value = "订单编号")
    private String orderNo;

    @ApiModelProperty(value = "订单创建时间")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date orderTime;

    @ApiModelProperty(value = "发票状态 0未开票、1申请中、2已开票")
    private Integer invoiceState;

    @ApiModelProperty(value = "卖家名称")
    private String sellerShopName;

    @ApiModelProperty(value = "买家名称")
    private String buyerShopName;

    @ApiModelProperty(value = "支付方式")
    private Integer payType;

    @ApiModelProperty(value = "订单商品")
    private List<OrderInfoGoodsVO> orderItem;

    @ApiModelProperty(value = "订单状态 0已取消 1未取消")
    private Integer orderState;
}
